﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Services.Protocols;

namespace SupplyChainWeb.Service
{
    public class UserValidationSoapHeader : SoapHeader
    {
        
        public string UserName { get; set; }

        public string Password { get; set; }

        public UserValidationSoapHeader()
        { }

        public bool IsValid()
        {
            if (string.IsNullOrEmpty(UserName) || string.IsNullOrEmpty(Password))
            {
                throw new Exception("用户名及密码不能为空！");
            }

            //if (E10LoginService.e10Lgoin(UserName,Password,null))
            //{
            //    throw new Exception("用户名或密码不正确！");
            //}
            return true;
        }


    }
}